home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
ETO Development Tools 4
/
ETO Development Tools 4.iso
/
Tools - Objects
/
Macintosh Programmer’s Workshop
/
MPW 3.1
/
SADE 1.1
/
SADEScripts
/
DisplayMemory
next >
Wrap
Text File
|
1990-12-13
|
902b
|
47 lines
# Symbolic Application Debugging Environment 1.0 Final
#
# Copyright Apple Computer, Inc. 1987-1988
# All rights reserved.
###############################################################################
#### Dm addr [, count] == memory display in hex and ASCII
proc dm a,n # display memory from address a for n bytes [default n = 16]
define i, j, b, s := ''
If undef(n) then
n := 16
end
for i := 1 to n do
if (i mod 16) = 1 then
if s <> '' then
printf " '%t'", s
end
if i <> 1 then
printf "\n"
end
printf "%.8X: ", a
s := ''
end
b := ^unsignedByte(a)^
printf "%.2X ", b
if (b < $20) | (b > $7E) then
s := concat(s, '.')
else
s := concat(s, cChar(b))
end
a := a + 1
end
if s <> '' then
if i > 16 then
i := i mod 16
if i <> 0 then
for j := i to 15 do
printf " "
end
end
end
printf " '%t'", s
end
printf "\n"
end